<template>
	<view>
		<view style="padding-bottom:80px ;">
			<home @AirdropIndex="homeIndex" v-if="indexs == 0"></home>
			<game v-if="indexs == 1"></game>
			<share v-if="indexs == 2"></share>
			<leaderboard v-if="indexs == 3"></leaderboard>
			<airdrop @AirdropIndex="AirdropIndex" v-if="indexs == 4"></airdrop>
		</view>
		<!-- 底部按钮 -->
		<own-baber :tabindexA="indexs" @tanCilck="tanCilck"></own-baber>
	</view>
</template>

<script>
	import home from './components/home/home.vue'
	import game from './components/Game/Game.vue'
	import share from './components/Share/Share.vue'
	import leaderboard from './components/leaderboard/leaderboard.vue'
	import airdrop from './components/Airdrop/Airdrop.vue'
	import OwnBaber from '@/components/ownTabar/ownTabar.vue'
	export default {
		components:{
			OwnBaber,
			home,
			share,
			leaderboard,
			airdrop,
			game
		},
		data() {
			return {
				indexs:0
			}
		},
		methods: {
			tanCilck(i){
				this.indexs = i
			},
			AirdropIndex(i){
				this.indexs = i
			},
			homeIndex(i){
				this.indexs = i
			}
		}
	}
</script>

<style>

</style>
